<?php declare(strict_types=1);


namespace App\Dao;



use App\Model\Model;

abstract class BaseDao
{

    /**
     * @param $model
     * @param $params
     * @return mixed
     */
    public function saveOne($model,$params)
    {
        $model->setRawAttributes($params);
        if($model->save()) {
            return $model;
        }
    }
}